import request from '@/utils/request'
import qs from 'qs'

export function getList(params) {
    return request({
        url: 'http://localhost:2345/classify/list',
        method: 'get',
        params
    })
}

export function addList(data) {
    return request({
        url: 'http://localhost:2345/classify/addList',
        method: 'post',
        data: qs.stringify(data)
    })
}

export function updateList(data) {
    return request({
        url: 'http://localhost:2345/classify/updateList',
        method: 'post',
        data: data
    })
}

export function deleteList(id) {
    return request({
        url: 'http://localhost:2345/classify/delList',
        method: 'get',
        params: {
            id
        }
    })
}